package c16多线程;

public class 尝试start已死亡的线程 {

	public static void main(String[] args) {
		Thread t = new Thread() {
			@Override
			public void run() {
				System.err.println(getName());
			}
		};
		t.start();
		try {
			Thread.sleep(1000);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		if (!t.isAlive()) {
			t.start();//此时线程已死亡，再调用此方法将会抛出异常：java.lang.IllegalThreadStateException
		}
	}

}
